<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
</head>

<body>
  <script>
    var y = 18
    //        true       26    || false 
    var x = (y > 9) && (y += 8) || y < 12
    console.log(x)  //26 
    // 运算符的优先级
    // () >  !  > 算数运算符>比较运算符>逻辑运算 &&和|| >赋值运算符

  </script>

</body>

</html>